<div class="monthDetail">
    <div style="position: absolute;z-index:9;margin:8px 0 0 8px">
        <ng-content></ng-content>
    </div>
    <nz-tabset [nzTabBarStyle]="{'margin-left':'90px'}" (nzSelectChange)="tabChange($event)">
        <nz-tab nzTitle="编制">
            <iframe [attr.src]="iframeSrc" frameborder="0" style="height: calc(100vh - 230px);width: 100%;"></iframe>
        </nz-tab>
        <nz-tab nzTitle="工作日程">
            <nz-table #table nzSize="small" [nzLoadingDelay]="1000" [nzShowPagination]="false"
                [nzFrontPagination]="false" [nzData]="tableData" nzBordered [nzScroll]="lockHeadScroll">
                <thead>
                    <tr>
                        <th nzWidth="50px" nzAlign="center">序号</th>
                        <th nzWidth="100px" nzAlign="center">作业类型</th>
                        <th nzWidth="300px" nzAlign="center">作业项目</th>
                        <th nzAlign="center" *ngFor="let date of dateTh">{{date}}</th>
                    </tr>
                </thead>
                <tbody>
                    <tr *ngFor="let data of table.data;let i = index">
                        <td nzAlign="center">{{+i+1}}</td>
                        <td>{{data.WORKTYPE}}</td>
                        <td>{{data.PROJECT}}</td>
                        <td nzAlign="center" *ngFor="let date of dateTh;let i = index">
                            {{data['A'+date] === 0 ? '--' : data['A'+date]}}
                        </td>
                    </tr>
                </tbody>
            </nz-table>
        </nz-tab>

        <nz-tab nzTitle="计划明细">
            <div class="searchWrap">
                来源：<input class="wd150" placeHolder="请输入来源" nz-input [(ngModel)]="searchParam.vcSourceShow" />
                &nbsp;&nbsp;&nbsp;
                作业类型：<input class="wd150" placeHolder="请输入作业类型" nz-input [(ngModel)]="searchParam.workType" />
                &nbsp;&nbsp;&nbsp;
                项目：<input class="wd150" placeHolder="请输入项目" nz-input [(ngModel)]="searchParam.project" />
                &nbsp;&nbsp;&nbsp;
                作业周次：<nz-select class="wd150" nzPlaceHolder="请输入作业周次" nzAllowClear [(ngModel)]="searchParam.weekindex">
                    <nz-option *ngFor="let item of weekList" [nzValue]="item.value" [nzLabel]="item.label"></nz-option>
                </nz-select>
                &nbsp;&nbsp;&nbsp;
                车站：<input class="wd150" placeHolder="请输入车站" nz-input [(ngModel)]="searchParam.staname" />
                &nbsp;&nbsp;&nbsp;
                设备名称：<input class="wd150" placeHolder="请输入设备名称" nz-input [(ngModel)]="searchParam.devname" />
                &nbsp;&nbsp;&nbsp;
                <button nz-button nzType="default" (click)="search()"><i nz-icon nzType="search"></i>查询</button>
            </div>

            <button style="margin:0 0 10px 5px" nz-button nzType="primary" (click)="wanChengFanKui(wcqkTemp)">
                <i nz-icon nzType="check-circle"></i>完成反馈</button>

            <nz-table #tableDetail nzSize="small" [nzScroll]="lockHeadScroll" [nzLoadingDelay]="1000"
                [nzShowPagination]="false" [nzFrontPagination]="false" [nzData]="tableDetailData" nzBordered>
                <thead>
                    <tr>
                        <th nzAlign="center" nzWidth="50px" nzShowCheckbox (nzCheckedChange)="checkAll($event)"></th>
                        <th nzAlign="center" nzWidth="50px">序号</th>
                        <th nzAlign="center" nzWidth="4%">是否完成</th>
                        <th nzAlign="center" nzWidth="4%">完成情况</th>
                        <th nzAlign="center" nzWidth="6%">调整时间</th>
                        <th nzAlign="center" nzWidth="7%">来源</th>
                        <th nzAlign="center" nzWidth="7%">作业类型</th>
                        <th nzAlign="center" nzWidth="10%">项目</th>
                        <th nzAlign="center" nzWidth="4%">作业周次</th>
                        <th nzAlign="center" nzWidth="6%">计划日期</th>
                        <th nzAlign="center" *ngIf="planDetail" nzWidth="7%">分劈部门</th>
                        <th nzAlign="center" nzWidth="7%">车站</th>
                        <th nzAlign="center" nzWidth="7%">设备名称</th>
                        <th nzAlign="center" nzWidth="5%">责任人</th>
                        <th nzAlign="center">备注</th>
                        <th nzAlign="center" nzWidth="6%">是否需要天窗</th>
                        <th nzAlign="center" nzWidth="6%">是否需要上道</th>
                    </tr>
                </thead>
                <tbody>
                    <tr *ngFor="let data of tableDetail.data;index as i">
                        <td nzShowCheckbox [(nzChecked)]="data.checked" (nzCheckedChange)="refreshStatus()"></td>
                        <td nzAlign="center">{{+i+1}}</td>
                        <td>{{statusList[data.vcFinish]?statusList[data.vcFinish]:'待反馈'}}</td>
                        <td nzAlign="center">{{data.vcFinished}}</td>
                        <td nzAlign="center">{{data.vcFinishdate}}</td>
                        <td>{{data.vcSourceShow}}</td>
                        <td>{{data.worktype}}</td>
                        <td>{{data.project}}</td>
                        <td>{{data.weekIndex}}</td>
                        <td nzAlign="center">{{data.workdaystr}}</td>
                        <td nzAlign="center" *ngIf="planDetail">{{data.vcSplitorgname}}</td>
                        <td nzAlign="center">{{data.staname}}</td>
                        <td nzAlign="center"><span style="word-break:break-all;">{{data.devname}}</span></td>
                        <td>{{data.vacharger}}</td>
                        <td>{{data.vcNote}}</td>
                        <td>{{data.needshywin}}</td>
                        <td>{{data.needroad}}</td>
                    </tr>
                </tbody>
            </nz-table>
        </nz-tab>
    </nz-tabset>
    <ng-template #wcqkTemp>
        <div nz-row>
            <div nz-col nzSpan="8" class="wcqkLable">
                是否完成
            </div>
            <div nz-col nzSpan="16" class="wcqkContent">
                <nz-radio-group [(ngModel)]="wcqkData.vcFinish" nzName="radiogroup">
                    <label nz-radio nzValue="1">已完成</label>
                    <label nz-radio nzValue="0">未完成</label>
                </nz-radio-group>
            </div>
        </div>
        <div nz-row>
            <div nz-col nzSpan="8" class="wcqkLable">
                完成情况
            </div>
            <div nz-col nzSpan="16" class="wcqkContent">
                <textarea nz-input [(ngModel)]="wcqkData.vcFinished" nzAutosize></textarea>
            </div>
        </div>
        <div nz-row *ngIf="wcqkData.vcFinish!=='1'">
            <div nz-col nzSpan="8" class="wcqkLable">
                调整日期
            </div>
            <div nz-col nzSpan="16" class="wcqkContent">
                <nz-date-picker [(ngModel)]="wcqkData._vcFinishdate" (ngModelChange)="wcqkDateChange($event)">
                </nz-date-picker>
            </div>
        </div>
    </ng-template>
</div>